﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<BadmintonBuddy.Models.Club>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Badminton Courts in <%= ViewData["Location"]%>, Play Badminton in <%= ViewData["Location"] %>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Badminton Courts in <%= ViewData["Location"]%></h2>

    <table>
        <tr>
            <th></th>
            
            <th>
                ClubName
            </th>
            <th>
                Address
            </th>            
        </tr>

    <% foreach (var item in Model) { %>
    
        <tr>
            <td>                
                <%= Html.ActionLink("Details", "Details", new { id=item.ClubID })%>                 
            </td>            
            <td>
                <%= Html.Encode(item.ClubName) %>
            </td>
            <td>
                <%= Html.Encode(item.Address) %>
            </td>            
        </tr>
    
    <% } %>

    </table>

    <p>
        <%= Html.ActionLink("Submit a Club", "Create") %> ||
        <%= Html.ActionLink("Browse all Clubs","Index") %>
    </p>

</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="MetaContent" runat="server">
</asp:Content>

